home *** CD-ROM | disk | FTP | other *** search
/ CICA 1994 April / CICA Shareware for Windows CD-ROM (Walnut Creek CD-ROM)(April 1994).ISO / win3 / nt / spi386.exe / OEMNADDS.IN_ / OEMNADDS.IN
INI File  |  1993-09-23  |  68KB  |  1,522 lines

  1. [Identification]
  2.     OptionType = NetAdapter
  3. [PlatformsSupported]
  4.     ISA
  5.     EISA
  6.     "Jazz-Internal Bus"
  7.     MCA
  8. [LanguagesSupported]
  9.     ENG
  10. [Options]
  11.     DigiBoardCX
  12.     DigiBoardXem
  13.     DigiBoard8i
  14.     DigiBoard16i
  15.     DigiBoard2Port
  16.     DigiBoard4Port
  17.     DigiBoard8Port
  18.     DigiBoard4e
  19.     DigiBoard8e
  20.     DigiBoard16e
  21. [OptionsMCA]
  22.     DigiBoardCX
  23.     DigiBoardXem
  24.     DigiBoard4i
  25.     DigiBoard8i
  26.     DigiBoard16i
  27.     DigiBoard2Port
  28.     DigiBoard4Port
  29.     DigiBoard8Port
  30. [AdapterInfo]
  31.     DigiBoardCX     = "C/X",    ntcx,       ntcx,     3,        {84240}
  32.     DigiBoardXem    = "PC/Xem", ntxem,      ntxem,    2,        {149776}
  33.     DigiBoard8i     = "PC/8i",  nt8i,       ntxall,   1,        {0}
  34.     DigiBoard16i    = "PC/16i", nt16i,      ntxall,   9,        {0}
  35.     DigiBoard2Port  = "2Port",  2Port,      ntxall,   4,        {0}
  36.     DigiBoard4Port  = "4Port",  4Port,      ntxall,   6,        {0}
  37.     DigiBoard8Port  = "8Port",  8Port,      ntxall,   7,        {0}
  38.     DigiBoard4e     = "PC/4e",  nt4e,       ntxall,   5,        {0}
  39.     DigiBoard8e     = "PC/8e",  nt8e,       ntxall,   0,        {0}
  40.     DigiBoard16e    = "PC/16e", nt16e,      ntxall,   8,        {0}
  41. [AdapterInfoMCA]
  42.     DigiBoardCX     = "MC C/X", ntcx,       ntcx,     3,        {28652,28648},   {236,232},  {111,111}
  43.     DigiBoardXem    = "MC/Xem", ntxem,      ntxem,    2,        {32668},         {156},      {127}
  44.     DigiBoard4i     = "MC/4i",  nt4i,       ntxall,   10,       {32666,32665},   {154,153},  {127,127}
  45.     DigiBoard8i     = "MC/8i",  nt8i,       ntxall,   1,        {32666,32665},   {154,153},  {127,127}
  46.     DigiBoard16i    = "MC/16i", nt16i,      ntxall,   9,        {32667},         {155},      {127}
  47.     DigiBoard2Port  = "2Port",  2Port,      ntxall,   4,        {28647},         {231},      {111}
  48.     DigiBoard4Port  = "4Port",  4Port,      ntxall,   6,        {28647},         {231},      {111}
  49.     DigiBoard8Port  = "8Port",  8Port,      ntxall,   7,        {28647},         {231},      {111}
  50. [FileConstants]
  51.     ExitState   = "Active"
  52.     OldVersionExisted = $(FALSE)
  53.     HdwDriverComponentExists = $(FALSE)
  54.     DriverPath      = $(!STF_NTPATH)"\drivers"
  55.     UtilityInf     = "UTILITY.INF"
  56.     subroutninf    = "SUBROUTN.INF"
  57.     ParamInf        = "NCPARAM.INF"
  58.     HandleNull   = ""
  59.     DGCONFIG_HANDLE = $(HandleNull)
  60. AdapterList = ^(AdapterInfo$(BusType),0)
  61. AdapterTitleList = ^(AdapterInfo$(BusType), 1)
  62. AdapterHardwareNameList = ^(AdapterInfo$(BusType), 2)
  63. AdapterHardwareDriverList = ^(AdapterInfo$(BusType), 3)
  64. AdapterHardwareTypeList = ^(AdapterInfo$(BusType), 4)
  65. AdapterHardwareAdapterIDList = ^(AdapterInfo$(BusType), 5)
  66. AdapterIDByte1List = ^(AdapterInfo$(BusType), 6)
  67. AdapterIDByte2List = ^(AdapterInfo$(BusType), 7)
  68. AdapterTitle = *($(AdapterTitleList), ~($(AdapterList), $(Option)))
  69. AdapterHardwareName = *($(AdapterHardwareNameList), ~($(AdapterList), $(Option)))
  70. AdapterHardwareDriver = *($(AdapterHardwareDriverList), ~($(AdapterList), $(Option)))
  71. AdapterHardwareType = *($(AdapterHardwareTypeList), ~($(AdapterList), $(Option)))
  72. AdapterHardwareAdapterID = *($(AdapterHardwareAdapterIDList), ~($(AdapterList), $(Option)))
  73. AdapterIDByte1 = *($(AdapterIDByte1List), ~($(AdapterList), $(Option)))
  74. AdapterIDByte2 = *($(AdapterIDByte2List), ~($(AdapterList), $(Option)))
  75. AdapterRule = *($(AdapterHardwareDriverList), ~($(AdapterList), $(Option)))
  76. AdapterServiceName = ""
  77. AdapterName = ""
  78.     NetEventDLL     = "%SystemRoot%\System32\netevent.dll"
  79.     IoLogMsgDLL     = "%SystemRoot%\System32\IoLogMsg.dll"
  80.     Manufacturer    = "DigiBoard"
  81.     ProductMajorVersion     = "3"
  82.     ProductMinorVersion     = "1"
  83.     ProductVersion  = $(ProductMajorVersion)"."$(ProductMinorVersion)
  84.     SoftwareType    = "driver"
  85.     ProductSoftwareName     = "DigiFEP5"
  86.     ProductSoftwareImagePath = "%SystemRoot%\System32\drivers\digifep5.sys"
  87.     NetRuleSoftwareType     = "digiFEP5Sys serialDriver digiFEP5Driver"
  88.     NetRuleSoftwareUse      = $(SoftwareType)
  89.     NetRuleSoftwareBindForm = """DigiFEP5Driver"" yes no container"
  90.     NetRuleSoftwareClass    = {"serialDriver basic","digiFEP5Driver basic"}
  91.     NetRuleSoftwareHiddenDriver   = 1
  92.     ProductMajorVersionHdwDriver     = "3"
  93.     ProductMinorVersionHdwDriver     = "1"
  94.     ProductVersionHdwDriver  = $(ProductMajorVersionHdwDriver)"."$(ProductMinorVersionHdwDriver)
  95.     ProductSoftwareNameHdwDriver = $(AdapterHardwareDriver)
  96.     ProductSoftwareImagePathHdwDriver = "%SystemRoot%\System32\drivers\"$(AdapterHardwareDriver)".sys"
  97.     NetRuleSoftwareTypeHdwDriver     = $(AdapterHardwareDriver)"sys "$(AdapterHardwareDriver)"Driver"
  98.     NetRuleSoftwareUseHdwDriver      = $(SoftwareType)
  99.     NetRuleSoftwareBindFormHdwDriver = """"$(AdapterHardwareDriver)"Driver"" yes no container"
  100.     NetRuleSoftwareClassHdwDriver    = {$(AdapterHardwareDriver)"Driver basic"}
  101.     NetRuleSoftwareHiddenHdwDriver   = 1
  102.     NetRuleHardwareType     = $(AdapterRule)" "$(AdapterRule)"Adapter"
  103.     NetRuleHardwareBindForm = " yes yes container"
  104.     NetRuleHardwareClass    = {$(AdapterHardwareDriver)"Adapter basic"}
  105.     ProductHardwareName         = $(AdapterHardwareDriver)
  106.     AdapterParameters = {}
  107.     ProductKeyName  = $(!NTN_SoftwareBase)"\"$(Manufacturer)"\"$(ProductSoftwareName)"\CurrentVersion"
  108.     ProductKeyNameHdwDriver  = $(!NTN_SoftwareBase)"\"$(Manufacturer)"\"$(ProductSoftwareNameHdwDriver)"\CurrentVersion"
  109.     ParamKeyName    = $(!NTN_ServiceBase)"\"$(ProductHardwareName)"\Parameters"
  110. [GeneralConstants]
  111.     ExitCodeOk     = 0
  112.     ExitCodeCancel = 1
  113.     ExitCodeFatal  = 2
  114.     KeyNull         = ""
  115.     MAXIMUM_ALLOWED   = 33554432
  116.     RegistryErrorIndex = NO_ERROR
  117.     KeyProduct      = ""
  118.     KeyParameters   = ""
  119.     TRUE         = 1
  120.     FALSE        = 0
  121.     NoTitle      = 0
  122.     fRemoveDigi = TRUE
  123. [DebugOptions]
  124.     !DebugOutputControl = 0
  125. [UiVars]
  126. from      = ""
  127. to        = ""
  128.     !STF_NTDRIVE        = ""
  129.     !STF_NTPATH         = ""
  130.     !STF_WINDOWSPATH    = "" ? $(!LIBHANDLE) GetWindowsNtDir
  131.     !STF_WINDOWSSYSPATH = "" ? $(!LIBHANDLE) GetWindowsNtSysDir
  132.     !STF_FLOPPYLIST     = {} ? $(!LIBHANDLE) GetFloppyDriveLetters
  133.     !STF_UNUSEDDRIVES   = {} ? $(!LIBHANDLE) GetUnusedDrives
  134.     !STF_LANGUAGE       = "ENG"
  135.     VolumeList      = {} ? $(!LIBHANDLE) GetHardDriveLetters
  136.     VolumeFreeList  = {} ? $(!LIBHANDLE) GetHardDriveFreeSpace
  137.     VolumeFSList    = {} ? $(!LIBHANDLE) GetHardDriveFileSystems
  138.     DestVolume      = ""
  139.     MinHelpID   = 25000
  140.     MaxHelpID   = 25999
  141. [date]
  142.     Now = {} ? $(!LIBHANDLE) GetSystemDate
  143. [Identify]
  144.     read-syms Identification
  145.     set Status     = STATUS_SUCCESSFUL
  146.     set Identifier = $(OptionType)
  147.     set Media      = #("Source Media Descriptions", 1, 1)
  148.     Return $(Status) $(Identifier) $(Media)
  149. [ReturnOptions]
  150.     set Status        = STATUS_FAILED
  151.     set OptionList     = {}
  152.     set OptionTextList = {}
  153.     set LanguageList = ^(LanguagesSupported, 1)
  154.     Ifcontains(i) $($0) in $(LanguageList)
  155.         ifstr(i) $($1) == ""
  156.             goto returnoptions
  157.         endif
  158.         set PlatformList = ^(PlatformsSupported, 1)
  159.         Ifcontains(i) $($1) in $(PlatformList)
  160.             goto returnoptions
  161.         else
  162.             set Status = STATUS_NOTSUPPORTED
  163.             goto finish_ReturnOptions
  164.         endif
  165.     Else
  166.         set Status = STATUS_NOLANGUAGE
  167.         goto finish_ReturnOptions
  168.     Endif
  169. returnoptions = +
  170.     ifstr(i) $($1) == "MCA"
  171.       set OptionList     = ^(OptionsMCA, 1)
  172.       set OptionTextList = ^(OptionsTextMCA$($0), 1)
  173.       set Status         = STATUS_SUCCESSFUL
  174.     else
  175.       set OptionList     = ^(Options, 1)
  176.       set OptionTextList = ^(OptionsText$($0), 1)
  177.       set Status         = STATUS_SUCCESSFUL
  178.     endif
  179. finish_ReturnOptions = +
  180.     Return $(Status) $(OptionList) $(OptionTextList)
  181. [Shell Commands]
  182.     set-title "Serial Setup"
  183.     set-subst LF = "\n"
  184.     set Exit_Code = $(ExitCodeOk)
  185.     Debug-Output "OEMNADDS.INF: STF_CWDDIR is "$(!STF_CWDDIR)
  186.     Debug-Output "OEMNADDS.INF: STF_RANFROM is "$(!STF_RANFROM)
  187.     ifstr(i) $(!STF_RANFROM) != ""
  188.         ifstr(i) $(!STF_RANFROM) != $(!STF_CWDDIR)"SERIAL\"
  189.            set !STF_SRCDIR = $(!STF_RANFROM)
  190.         endif
  191.     endif
  192.     LoadLibrary "x" $(!STF_CWDDIR)setupdll.dll !LIBHANDLE
  193.     shell "" InstallOption ENG DigiBoard $(!STF_SRCDIR)
  194.     FreeLibrary $(!LIBHANDLE)
  195.     set Status = $($R0)
  196.     Return $(Status)
  197. [InstallOption]
  198.     read-syms DebugOptions
  199.     Debug-Output "OEMNADDS.INF: In [InstallOption] section"
  200.     set Status = STATUS_FAILED
  201.     set Option    = $($1)
  202.     set SrcDir    = $($2)
  203.     set AddCopy   = $($3)
  204.     set DoCopy    = $($4)
  205.     set DoConfig  = $($5)
  206.     set !SourceDir = $($2)
  207.     set BusType = ""
  208.     ifstr(i) $(!STF_BUSTYPE) == "MCA"
  209.       set BusType = "MCA"
  210.     endif
  211.     read-syms GeneralConstants
  212.     read-syms FileConstants
  213.     Debug-Output "OEMNADDS.INF: Language = "$($0)
  214.     Debug-Output "OEMNADDS.INF: OptionID = "$($1)
  215.     Debug-Output "OEMNADDS.INF: SourceDirectory = "$($2)
  216.     Debug-Output "OEMNADDS.INF: AddCopy = "$(AddCopy)
  217.     Debug-Output "OEMNADDS.INF: DoCopy = "$(DoCopy)
  218.     Debug-Output "OEMNADDS.INF: DoConfig = "$(DoConfig)
  219.     set LanguageList = ^(LanguagesSupported, 1)
  220.     Ifcontains(i) $($0) NOT-IN $(LanguageList)
  221.         Debug-Output "OEMNADDS.INF: returning STATUS_NO_LANGUAGE"
  222.         return STATUS_NOLANGUAGE
  223.     Endif
  224.     set-subst LF = "\n"
  225.     Debug-Output "OEMNADDS.INF: AdapterTitle = "$(AdapterTitle)
  226.     Debug-Output "OEMNADDS.INF: AdapterHardwareName = "$(AdapterHardwareName)
  227.     Debug-Output "OEMNADDS.INF: AdapterHardwareDriver = "$(AdapterHardwareDriver)
  228.     read-syms BindingInfo-DigiFEP5
  229.     set NetRuleSoftwareBindable = $(BindingInfo)
  230.     read-syms BindingInfo-$(AdapterHardwareDriver)
  231.     set NetRuleSoftwareBindableHdwDriver = $(BindingInfo)
  232.     read-syms DialogConstants$(!STF_LANGUAGE)
  233.     ifstr(i) $(!NTN_Origination) == "NCPA"
  234.         set Continue = "OK"
  235.     endif
  236.     read-syms FileConstants$(!STF_LANGUAGE)
  237.     detect date
  238.     set-title  $(FunctionTitle)
  239.     set to   = Begin
  240.     set from = Begin
  241.     set CommonStatus = STATUS_SUCCESSFUL
  242.     EndWait
  243. Begin = +
  244.     Ifstr(i) $(!NTN_InstallMode) == deinstall
  245.         set StartLabel = removeadapter
  246.     else-Ifstr(i) $(!NTN_InstallMode) == Update
  247.         set StartLabel = UpgradeSoftware
  248.     else-Ifstr(i) $(!NTN_InstallMode) == bind
  249.         set StartLabel = bindingadapter
  250.     else-Ifstr(i) $(!NTN_InstallMode) == configure
  251.         set StartLabel = getAdapterSettings
  252.         Ifstr(i) $(ProductKeyName) == $(!NTN_RegBase)
  253.             Debug-Output "Cannot configure the DigiBoard FEP 5 driver software."
  254.             Shell $(UtilityInf),RegistryErrorString,CANNOT_CONFIGURE_SOFTWARE
  255.             ifint $($ShellCode) != $(!SHELL_CODE_OK)
  256.                 Debug-Output "ShellCode error: cannot get an error string."
  257.                 goto ShellCodeError
  258.             endif
  259.             set Error = $($R0)
  260.             set from = end
  261.             set to = end
  262.             goto nonfatalinfo
  263.         endif
  264.         Ifstr(i) $(ProductKeyNameHdwDriver) == $(!NTN_RegBase)
  265.             Debug-Output "This should not have happened!  Cannot configure the "$(AdapterHardwareName)" driver software."
  266.             Shell $(UtilityInf),RegistryErrorString,CANNOT_CONFIGURE_SOFTWARE
  267.             ifint $($ShellCode) != $(!SHELL_CODE_OK)
  268.                 Debug-Output "ShellCode error: cannot get an error string."
  269.                 goto ShellCodeError
  270.             endif
  271.             set Error = $($R0)
  272.             set from = end
  273.             set to = end
  274.             goto nonfatalinfo
  275.         endif
  276.         Debug-Output "We need to determine how to find out which adapter"
  277.         Debug-Output "  we should be configuring!!!!!!"
  278.         set from = writeparameters
  279.         Debug-Output "setting from = "$(from)
  280.     else
  281.         set StartLabel = installadapter
  282.         set OEM_ABANDON_OPTIONS = {}
  283.         set OEM_ABANDON_SOFTWARE = FALSE
  284.         set OEM_ABANDON_ON = TRUE
  285.     endif
  286.     Debug-Output "OEMNADDS.INF: Option is: "$(Option)
  287.     set to = $(fatal)
  288.     Goto $(StartLabel)
  289. installadapter = +
  290.     Debug-Output "******************Entering installadapter******************"
  291.     OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct
  292.     Ifstr $(KeyProduct) != $(KeyNull)
  293.         CloseRegKey $(KeyProduct)
  294.         ifstr(i) $(!NTN_RegBase) == $(ProductKeyName)
  295.            Shell $(UtilityInf), VerExistedDlg, $(ProductSoftwareTitle),+
  296.                $(ProductVersion)
  297.            ifint $($ShellCode) != $(!SHELL_CODE_OK)
  298.                Debug-Output "ShellCode error: Don't allow installation of software."
  299.                goto ShellCodeError
  300.            endif
  301.            goto end
  302.         else
  303.             OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyNameHdwDriver) +
  304.                        $(MAXIMUM_ALLOWED) KeyProductHdwDriver
  305.             Ifstr $(KeyProductHdwDriver) != $(KeyNull)
  306.                 CloseRegKey $(KeyProductHdwDriver)
  307.                 Shell $(UtilityInf), CardExistedDlg
  308.                 ifint $($ShellCode) != $(!SHELL_CODE_OK)
  309.                     Debug-Output "ShellCode error: --One adapter all ready exists, install another-- FAILED."
  310.                     goto ShellCodeError
  311.                 endif
  312.                 ifstr(i) $($R1) != "OK"
  313.                     goto end
  314.                 endif
  315.                 set HdwDriverComponentExists = $(TRUE)
  316.             EndIf   
  317.             set OldVersionExisted = $(TRUE)
  318.         endif
  319.     endif
  320.     goto skipoptions
  321. skipoptions = +
  322.     Debug-Output "******************Entering skipoptions******************"
  323.     ifint $(HdwDriverComponentExists) == $(TRUE)
  324.         ifstr(i) $(!NTN_InstallMode) == configure
  325.             goto getAdapterSettings
  326.         endif
  327.     endif
  328.     StartWait
  329.     ifint $(HdwDriverComponentExists) == $(FALSE)
  330.         ifstr(i) $(!NTN_InstallMode) == "install"
  331.            shell $(UtilityInf) AssignAdapterNumber
  332.            set AdapterName = $(ProductHardwareName)$($R1)
  333.            Ifstr(i) $(DoCopy) == "YES"
  334.               Shell $(UtilityInf), DoAskSource, $(!STF_CWDDIR), $(SrcDir) YES
  335.               Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  336.                   Debug-Output"Shell code error: DoAskSource"
  337.                   Goto ShellCodeError
  338.               Else-Ifstr(i) $($R0) == STATUS_FAILED
  339.                   Shell $(UtilityInf) RegistryErrorString "ASK_SOURCE_FAIL"
  340.                   ifint $($ShellCode) != $(!SHELL_CODE_OK)
  341.                       goto ShellCodeError
  342.                   endif
  343.                   set Error = $($R0)
  344.                   Goto fatal
  345.               Else-Ifstr(i) $($R0) == STATUS_USERCANCEL
  346.                   set CommonStatus = STATUS_USERCANCEL
  347.                   Goto successful
  348.               Endif
  349.               Set SrcDir = $($R1)
  350.            Endif
  351.            install "Install-Option"
  352.            ifstr(i) $(STF_INSTALL_OUTCOME) != STF_SUCCESS
  353.               Shell $(UtilityInf) RegistryErrorString "UNABLE_COPY_FILE"
  354.               ifint $($ShellCode) != $(!SHELL_CODE_OK)
  355.                   goto ShellCodeError
  356.               endif
  357.               set Error = $($R0)
  358.               goto fatal
  359.            endif
  360.         endif
  361.     endif
  362.     set from = addDigiFEP5Component
  363.     goto getAdapterSettings
  364. addDigiFEP5Component = +
  365.     Debug-Output "******************Entering addDigiFEP5Component******************"
  366.     Ifint $(OldVersionExisted) == $(TRUE)
  367.         goto addHdwDriverComponent
  368.     Endif
  369.     Debug-Output "OEMNADDS.INF: Adding DigiFEP5Component"
  370.         set DigiSpecificString = $(ProductSoftwareName)
  371.         set TypeofService = "kernelautostart"
  372.         set ServiceOrderGroup = "Extended base"
  373.         set Dependencies = {}
  374.         set ObjectName = ""
  375.         set TypeSupported = "7"
  376.         set EventLogLocation = "System"
  377.         set ErrorControlValue = 1
  378.         Debug-Output "OEMNADDS.INF: [InstallOption]:skipoptions: About to call AddSoftwareComponent"
  379.         Debug-Output "OEMNADID.INF:     Paramters passed in:"
  380.         Debug-Output "OEMNADDS.INF:         Manufacturer = "$(Manufacturer)
  381.         Debug-Output "OEMNADDS.INF:         Product = "$(ProductSoftwareName)
  382.         Debug-Output "OEMNADDS.INF:         Service = "$(ProductSoftwareName)
  383.         Debug-Output "OEMNADDS.INF:         Display name = "$(ProductSoftwareTitle)
  384.         Debug-Output "OEMNADDS.INF:         INFfile = "$(STF_CONTEXTINFNAME)
  385.         Debug-Output "OEMNADDS.INF:         ImagePath = "$(ProductSoftwareImagePath)
  386.         Debug-Output "OEMNADDS.INF:         Type of software = "$(TypeofService)
  387.         Debug-Output "OEMNADDS.INF:         Service Order group = "$(ServiceOrderGroup)
  388.         Debug-Output "OEMNADDS.INF:         Dependencies = "$(Dependencies)
  389.         Debug-Output "OEMNADDS.INF:         ObjectName = "$(ObjectName)
  390.         Debug-Output "OEMNADDS.INF:         EventMessageFile = "$(IoLogMsgDLL)";"$(ProductSoftwareImagePath)
  391.         Debug-Output "OEMNADDS.INF:         TypeSupported = "$(TypeSupported)
  392.         Debug-Output "OEMNADDS.INF:         Event log location = "$(EventLogLocation)
  393.         Debug-Output "OEMNADDS.INF:         Error control value = "$(ErrorControlValue)
  394.         Shell $(UtilityInf), AddSoftwareComponent, +
  395.                                     $(Manufacturer), +
  396.                                     $(ProductSoftwareName), +
  397.                                     $(ProductSoftwareName), +
  398.                                     $(ProductSoftwareTitle), +
  399.                                     $(STF_CONTEXTINFNAME), +
  400.                                     $(ProductSoftwareImagePath), +
  401.                                     $(TypeofService), +
  402.                                     $(ServiceOrderGroup), +
  403.                                     $(Dependencies), +
  404.                                     $(ObjectName), +
  405.                                     $(IoLogMsgDLL)";"$(ProductSoftwareImagePath), +
  406.                                     $(TypeSupported), +
  407.                                     $(EventLogLocation), +
  408.                                     $(ErrorControlValue)
  409.         Set OEM_ABANDON_SOFTWARE = TRUE
  410.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  411.             Debug-Output "ShellCode error: Add software component FAILED!"
  412.             goto ShellCodeError
  413.         endif
  414.         set RegistryErrorIndex = $($R0)
  415.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  416.             EndWait
  417.             Debug-Output "Registry error: add software components"
  418.             CloseRegKey $($R1)
  419.             CloseRegKey $($R2)
  420.             CloseRegKey $($R3)
  421.             CloseRegKey $($R4)
  422.             CloseRegKey $($R5)
  423.             goto fatalregistry
  424.         endif
  425.         Set SoftProductKey      = $($R1)
  426.         Set SoftNetRuleKey      = $($R2)
  427.         Set SoftServiceKey      = $($R3)
  428.         Set SoftParameterKey    = $($R4)
  429.         Set SoftLinkageKey      = $($R5)
  430.         set NewValueList = {{SoftwareType,$(NoTitle),$(!REG_VT_SZ),$(SoftwareType)},+
  431.                            {MajorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMajorVersion)},+
  432.                            {MinorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMinorVersion)},+
  433.                            {Title,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareTitle)},+
  434.                            {Description,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareDescription)},+
  435.                            {ServiceName,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareName)},+
  436.                            {hidden,$(NoTitle),$(!REG_VT_DWORD),$(NetRuleSoftwareHiddenDriver)}, +
  437.                            {InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}}
  438.         Shell  $(UtilityInf), AddValueList, $(SoftProductKey), $(NewValueList)
  439.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  440.             Debug-Output "ShellCode error: AddValueList FAILED!  --"$(SoftProductKey)
  441.             goto ShellCodeError
  442.         endif
  443.         set RegistryErrorIndex = $($R0)
  444.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  445.             EndWait
  446.             Debug-Output "Registry error: add value list."
  447.             CloseRegKey $(SoftProductKey)
  448.             CloseRegKey $(SoftNetRuleKey)
  449.             CloseRegKey $(SoftServiceKey)
  450.             CloseRegKey $(SoftParameterKey)
  451.             CloseRegKey $(SoftLinkageKey)
  452.             goto fatalregistry
  453.         endif
  454.         set NewValueList = {{type,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareType)},+
  455.                             {use,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareUse)}, +
  456.                             {bindform,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareBindForm)}, +
  457.                             {class,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareClass)}, +
  458.                             {bindable,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareBindable)}, +
  459.                             {InfOption,$(NoTitle),$(!REG_VT_SZ),$(Option)}}
  460.         Shell  $(UtilityInf), AddValueList, $(SoftNetRuleKey), $(NewValueList)
  461.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  462.             Debug-Output "ShellCode error: AddValueList FAILED! --"$(SoftNetRuleKey)
  463.             goto ShellCodeError
  464.         endif
  465.         set RegistryErrorIndex = $($R0)
  466.         FlushRegKey $(SoftProductKey)
  467.         FlushRegKey $(SoftNetRuleKey)
  468.         FlushRegKey $(SoftServiceKey)
  469.         FlushRegKey $(SoftParameterKey)
  470.         FlushRegKey $(SoftLinkageKey)
  471.         CloseRegKey $(SoftProductKey)
  472.         CloseRegKey $(SoftNetRuleKey)
  473.         CloseRegKey $(SoftServiceKey)
  474.         CloseRegKey $(SoftParameterKey)
  475.         CloseRegKey $(SoftLinkageKey)
  476.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  477.             EndWait
  478.             Debug-Output "Registry error: add value list."
  479.             goto fatalregistry
  480.         endif
  481.         goto addHdwDriverComponent
  482. addHdwDriverComponent = +
  483.     Debug-Output "******************Entering addHdwDriverComponent******************"
  484.     set DigiSpecificString = $(AdapterHardwareName)
  485.     Ifint $(HdwDriverComponentExists) == $(TRUE)
  486.         goto addAdapterComponent
  487.     Endif
  488.     Debug-Output "OEMNADDS.INF: Adding HdwDriverComponent"
  489.         set TypeofService = "kernelautostart"
  490.         set ServiceOrderGroup = "Extended base"
  491.         set Dependencies = {}
  492.         set ObjectName = ""
  493.         set TypeSupported = "7"
  494.         set EventLogLocation = "System"
  495.         set ErrorControlValue = 1
  496.         Shell $(UtilityInf), AddSoftwareComponent, +
  497.                                     $(Manufacturer), +
  498.                                     $(ProductSoftwareNameHdwDriver), +
  499.                                     $(ProductSoftwareNameHdwDriver), +
  500.                                     $(ProductSoftwareTitleHdwDriver), +
  501.                                     $(STF_CONTEXTINFNAME), +
  502.                                     $(ProductSoftwareImagePathHdwDriver), +
  503.                                     $(TypeofService), +
  504.                                     $(ServiceOrderGroup), +
  505.                                     $(Dependencies), +
  506.                                     $(ObjectName), +
  507.                                     $(IoLogMsgDLL)";"$(ProductSoftwareImagePathHdwDriver), +
  508.                                     $(TypeSupported), +
  509.                                     $(EventLogLocation), +
  510.                                     $(ErrorControlValue)
  511.         Set OEM_ABANDON_SOFTWARE = TRUE
  512.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  513.             Debug-Output "ShellCode error: AddSoftwareComponent FAILED! -- "$(ProductSoftwareNameHdwDriver)
  514.             goto ShellCodeError
  515.         endif
  516.         set RegistryErrorIndex = $($R0)
  517.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  518.             EndWait
  519.             Debug-Output "Registry error: add software components"
  520.             CloseRegKey $($R1)
  521.             CloseRegKey $($R2)
  522.             CloseRegKey $($R3)
  523.             CloseRegKey $($R4)
  524.             CloseRegKey $($R5)
  525.             goto fatalregistry
  526.         endif
  527.         Set SoftProductKey      = $($R1)
  528.         Set SoftNetRuleKey      = $($R2)
  529.         Set SoftServiceKey      = $($R3)
  530.         Set SoftParameterKey    = $($R4)
  531.         Set SoftLinkageKey      = $($R5)
  532.         set NewValueList = {{SoftwareType,$(NoTitle),$(!REG_VT_SZ),$(SoftwareType)},+
  533.                            {MajorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMajorVersionHdwDriver)},+
  534.                            {MinorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMinorVersionHdwDriver)},+
  535.                            {Title,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareTitleHdwDriver)},+
  536.                            {Description,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareDescriptionHdwDriver)},+
  537.                            {ServiceName,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareNameHdwDriver)},+
  538.                            {hidden,$(NoTitle),$(!REG_VT_DWORD),$(NetRuleSoftwareHiddenHdwDriver)}, +
  539.                            {InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}}
  540.         Shell  $(UtilityInf), AddValueList, $(SoftProductKey), $(NewValueList)
  541.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  542.             Debug-Output "ShellCode error: AddValueList FAILED!  -- "$(SoftProductKey)
  543.             goto ShellCodeError
  544.         endif
  545.         set RegistryErrorIndex = $($R0)
  546.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  547.             EndWait
  548.             Debug-Output "Resgitry error: add value list."
  549.             CloseRegKey $(SoftProductKey)
  550.             CloseRegKey $(SoftNetRuleKey)
  551.             CloseRegKey $(SoftServiceKey)
  552.             CloseRegKey $(SoftParameterKey)
  553.             CloseRegKey $(SoftLinkageKey)
  554.             goto fatalregistry
  555.         endif
  556.         set NewValueList = {{type,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareTypeHdwDriver)},+
  557.                             {use,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareUseHdwDriver)}, +
  558.                             {bindform,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareBindFormHdwDriver)}, +
  559.                             {class,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareClassHdwDriver)}, +
  560.                             {bindable,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareBindableHdwDriver)}, +
  561.                             {InfOption,$(NoTitle),$(!REG_VT_SZ),$(Option)}}
  562.         Shell  $(UtilityInf), AddValueList, $(SoftNetRuleKey), $(NewValueList)
  563.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  564.             Debug-Output "ShellCode error. AddValueList FAILED!  -- "$(SoftNetRuleKey)
  565.             goto ShellCodeError
  566.         endif
  567.         set RegistryErrorIndex = $($R0)
  568.         FlushRegKey $(SoftProductKey)
  569.         FlushRegKey $(SoftNetRuleKey)
  570.         FlushRegKey $(SoftServiceKey)
  571.         FlushRegKey $(SoftParameterKey)
  572.         FlushRegKey $(SoftLinkageKey)
  573.         CloseRegKey $(SoftProductKey)
  574.         CloseRegKey $(SoftNetRuleKey)
  575.         CloseRegKey $(SoftServiceKey)
  576.         CloseRegKey $(SoftParameterKey)
  577.         CloseRegKey $(SoftLinkageKey)
  578.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  579.             EndWait
  580.             Debug-Output "Registry error: add value list."
  581.             goto fatalregistry
  582.         endif
  583. addAdapterComponent = +
  584.     Debug-Output "******************Entering addAdapterComponent******************"
  585.     Shell $(UtilityInf), AddHardwareComponent, $(ProductHardwareName), +
  586.                                     $(STF_CONTEXTINFNAME), $(ProductKeyNameHdwDriver)
  587.     ifint $($R4) != -1
  588.         Set OEM_ABANDON_OPTIONS = >($(OEM_ABANDON_OPTIONS), $(!NTN_SoftwareBase)"\Microsoft\Windows NT\CurrentVersion\NetworkCards\"$($R4))
  589.     endif
  590.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  591.         Debug-Output "Cannot add hardware component!"
  592.         goto ShellCodeError
  593.     endif
  594.     set RegistryErrorIndex = $($R0)
  595.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  596.         EndWait
  597.         Debug-Output "Registry error: add hardware component"
  598.         Debug-Output $(RegistryErrorIndex)
  599.         CloseRegKey $($R1)
  600.         CloseRegKey $($R2)
  601.         CloseRegKey $($R3)
  602.         goto fatalregistry
  603.     endif
  604.     set KeyParameters = $($R3)
  605.     set KeyAdapterRules = $($R2)
  606.     set AdapterNumber = $($R4)
  607.     set AdapterServiceName = $($R5)
  608.     set AdapterName = $(AdapterServiceName)
  609.     set NewValueList = {{Manufacturer,$(NoTitle),$(!REG_VT_SZ),$(Manufacturer)},+
  610.                        {Title,$(NoTitle),$(!REG_VT_SZ),"["$($R4)"] "$(ProductHardwareTitle)},+
  611.                        {Description,$(NoTitle),$(!REG_VT_SZ),$(ProductHardwareDescription)},+
  612.                        {ProductName,$(NoTitle),$(!REG_VT_SZ),$(ProductHardwareName)},+
  613.                        {ServiceName,$(NoTitle),$(!REG_VT_SZ),$($R5)},+
  614.                        {InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}}
  615.     Shell  $(UtilityInf), AddValueList, $($R1), $(NewValueList)
  616.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  617.         Debug-Output "ShellCode error: AddValueList FAILED  -- "$($R1)
  618.         goto ShellCodeError
  619.     endif
  620.     shell $(UtilityInf) IncrementRefCount $(ProductKeyName)
  621.     set TempProdName = """"$(ProductHardwareName)$(AdapterNumber)""""
  622.     set TempBindForm = $(TempProdName)$(NetRuleHardwareBindForm)
  623.     set NewValueList = {{type,$(NoTitle),$(!REG_VT_SZ),$(NetRuleHardwareType)},+
  624.                         {bindform,$(NoTitle),$(!REG_VT_SZ),$(TempBindForm)}, +
  625.                         {class,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleHardwareClass)}, +
  626.                         {InfOption,$(NoTitle),$(!REG_VT_SZ),$(Option)}}
  627.     Shell  $(UtilityInf), AddValueList, $(KeyAdapterRules), $(NewValueList)
  628.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  629.         Debug-Output "ShellCode error."
  630.         goto ShellCodeError
  631.     endif
  632.     set RegistryErrorIndex = $($R0)
  633.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  634.         EndWait
  635.         Debug-Output "Resgitry error: add value list."
  636.         CloseRegKey $(KeyParameters)
  637.         CloseRegKey $(KeyAdapterRules)
  638.         goto fatalregistry
  639.     endif
  640.     FlushRegKey $(KeyParameters)
  641.     FlushRegKey $(KeyAdapterRules)
  642.     CloseRegKey $(KeyParameters)
  643.     CloseRegKey $(KeyAdapterRules)
  644.     goto writeparameters
  645. configureadapter = +
  646.     Debug-Output "******************Entering configureadapter******************"
  647.     Debug-Output "OEMNADDS.INF: PortNameList = "$(PortNameList)
  648.     QueryListSize IRQRangeListSize $(IRQRangeList)
  649.     QueryListSize MemoryRangeListSize $(MemoryRangeList)
  650.     QueryListSize IORangeListSize $(IORangeList)
  651.     QueryListSize PortNameListSize $(PortNameList)
  652.     LibraryProcedure Result, $(DGCONFIG_HANDLE), +
  653.             DGConfigEntryPoint, $(!STF_HWND), $(AdapterHardwareType), +
  654.                 $(ConfigurationTitle), +
  655.                 $(IRQRangeList), +
  656.                 $(IRQRangeListSize), +
  657.                 $(IRQDefault), +
  658.                 $(MemoryRangeList), +
  659.                 $(MemoryRangeListSize), +
  660.                 $(MemoryDefault), +
  661.                 $(IORangeList), +
  662.                 $(IORangeListSize), +
  663.                 $(IODefault), +
  664.                 $(CtrlList), +
  665.                 $(AdapterName)
  666.     Debug-Output $(Result)
  667.     Ifstr $(Result) == "{}"
  668.         set CommonStatus = STATUS_USERCANCEL
  669.         goto successful
  670.     Endif
  671.     set AdapterParameters = $(Result)
  672.     read-syms UpdatingConfiguration$(!STF_LANGUAGE)
  673.     shell $(subroutninf) PushBillBoard NETSTATUSDLG $(UpdatingConfiguration)
  674.     Debug-Output "jumping to "$(from)
  675.     goto $(from)
  676. getAdapterSettings = +
  677.     Debug-Output "******************Entering getAdapterSettings******************"
  678.     Debug-Output "from value = "$(from)
  679.     set IRQDefault = 0
  680.     set MemoryDefault = 3
  681.     set IODefault = 4
  682.     LoadLibrary "x" dgconfig.dll DGCONFIG_HANDLE
  683.     read-syms AdapterSettings-$(AdapterHardwareName)
  684.     Ifstr $(!NTN_RegBase) != $(KeyNull)
  685.         OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) $(MAXIMUM_ALLOWED) SoftwareKey
  686.         Ifstr $(SoftwareKey) == $(KeyNull)
  687.             Debug-Output "Unable to open "$(!NTN_RegBase)" key!!!!"
  688.             goto getAdapterSettingsExit
  689.         Else
  690.             GetRegValue $(SoftwareKey), "ServiceName", ServiceNameList
  691.             set AdapterServiceName = *($(ServiceNameList),4)
  692.             set AdapterName = $(AdapterServiceName)
  693.             CloseRegKey $(SoftwareKey)
  694.         Endif
  695.     Endif
  696.     Debug-Output "AdapterServiceName = "$(AdapterServiceName)
  697.     Debug-Output "AdapterName = "$(AdapterName)
  698.     OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(AdapterServiceName) $(MAXIMUM_ALLOWED) BaseKey
  699.     Ifstr $(BaseKey) == $(KeyNull)
  700.         Debug-Output "Error opening BaseKey "$(!NTN_ServiceBase)"\"$(AdapterServiceName)
  701.         CloseRegKey $(BaseKey)
  702.         goto fatalregistry
  703.     Endif
  704.     set BusTypeNum = 1
  705.     OpenRegKey $(BaseKey) "" "Parameters" $(MAXIMUM_ALLOWED) ParametersKey
  706.     Ifstr $(ParametersKey) == $(KeyNull)
  707.         Debug-Output "Assuming Parameters key does not exist!!!"
  708.         ifstr(i) $(BusType) == "MCA"
  709.             ForListDo $(AdapterHardwareAdapterID)
  710.                Debug-Output "Calling MCAFindBus, "*($(AdapterIDByte1),$(#))", "*($(AdapterIDByte2),$(#))
  711.                Shell $(UtilityInf), MCAFindBus, *($(AdapterIDByte1),$(#)), *($(AdapterIDByte2),$(#))
  712.                Debug-Output "MCAFindBus returned "$($R1)
  713.                set CardInfo = {}
  714.                ifstr(i) $($R1) != {}
  715.                   set CardInfo = $($R1)
  716.                   Debug-Output "MCA controller found!"
  717.                   Debug-Output "CardInfo = "$(CardInfo)
  718.                   ForListDo $(CardInfo)
  719.                      Debug-Output "Current CardInfo Entry = "$($)
  720.                      set TmpBusNumber = *($($), 1)
  721.                      set SlotNumber = *($($), 2)
  722.                      set MCAPosId = *($($), 3)
  723.                      Debug-Output "Calling DoesControllerExist:"
  724.                      Debug-Output "    AdapterHardwareName = "$(AdapterHardwareName)
  725.                      Debug-Output "    BusNumber = "$(TmpBusNumber)
  726.                      Debug-Output "    Slot # = "$(SlotNumber)
  727.                      Debug-Output " DGCONFIG_HANDLE = "$(DGCONFIG_HANDLE)
  728.                      LibraryProcedure Result, $(DGCONFIG_HANDLE), +
  729.                         DoesControllerExist, $(AdapterHardwareName), +
  730.                                              $(TmpBusNumber),        +
  731.                                              $(SlotNumber)
  732.                      Debug-Output "DoesControllerExist return: "$(Result)
  733.                      ifstr(i) $(Result) == "FALSE"
  734.                         Debug-Output "Before resetting IORangeList for MCA: "$(IORangeList)
  735.                         set IORangeList = {Slot$(SlotNumber)}
  736.                         set IODefault = 0
  737.                         Debug-Output "After resetting IORangeList for MCA: "$(IORangeList)
  738.                         Debug-Output "Before resetting MemoryRangeList for MCA: "$(MemoryRangeList)
  739.                         set MemoryDefault = 0
  740.                         set MemoryRangeList = {Slot$(SlotNumber)}
  741.                         Debug-Output "After resetting MemoryRangeList for MCA: "$(MemoryRangeList)
  742.                         set BusTypeNum = 3
  743.                         goto getAdapterSettingsExit
  744.                      endif
  745.                   EndForListDo
  746.                endif
  747.             EndForListDo
  748.         else
  749.             ForListDo $(AdapterHardwareAdapterID)
  750.               ifint $($) != 0
  751.                   Debug-Output "Calling EISAFindBus, "$($)
  752.                   Shell $(UtilityInf), EISAFindBus, $($)
  753.                   set CardInfo = {}
  754.                   ifstr(i) $($R1) != {}
  755.                      set CardInfo = $($R1)
  756.                      Debug-Output "EISA controller found!"
  757.                      Debug-Output "CardInfo = "$(CardInfo)
  758.                       ForListDo $(CardInfo)
  759.                          Debug-Output "Current CardInfo Entry = "$($)
  760.                          set TmpBusNumber = *($($), 1)
  761.                          set SlotNumber = *($($), 2)
  762.                          set-mul NewIOBaseAddress = $(SlotNumber), 4096
  763.                          set-add NewIOBaseAddress = $(NewIOBaseAddress), 5
  764.                          set-dectohex NewIOBaseAddress = $(NewIOBaseAddress)
  765.                          Debug-Output "Calling DoesControllerExist:"
  766.                          Debug-Output "    AdapterHardwareName = "$(AdapterHardwareName)
  767.                          Debug-Output "    BusNumber = "$(TmpBusNumber)
  768.                          Debug-Output "    NewIOBaseAddress = "$(NewIOBaseAddress)
  769.                          Debug-Output " DGCONFIG_HANDLE = "$(DGCONFIG_HANDLE)
  770.                          LibraryProcedure Result, $(DGCONFIG_HANDLE), +
  771.                             DoesControllerExist, $(AdapterHardwareName), +
  772.                                                  $(TmpBusNumber),        +
  773.                                                  $(NewIOBaseAddress)
  774.                          Debug-Output "DoesControllerExist return: "$(Result)
  775.                          ifstr(i) $(Result) == "FALSE"
  776.                             Debug-Output "Before resetting IORangeList for EISA: "$(IORangeList)
  777.                             set IORangeList = {$(NewIOBaseAddress)}
  778.                             set IODefault = 0
  779.                             Debug-Output "After resetting IORangeList for EISA: "$(IORangeList)
  780.                             set BusTypeNum = 2
  781.                             goto getAdapterSettingsExit
  782.                          endif
  783.                       EndForListDo
  784.                   endif
  785.                endif
  786.             EndForListDo
  787.         endif
  788.         CloseRegKey $(BaseKey)
  789.         goto configureadapter
  790.     Endif
  791.     GetRegValue $(ParametersKey) "MemoryMappedBaseAddress" MemoryMappedValueList
  792.     GetRegValue $(ParametersKey) "InterruptNumber" IRQValueList
  793.     GetRegValue $(ParametersKey) "IOBaseAddress" IOBaseValueList
  794.     ifstr(i) $(BusType) != "MCA"
  795.        set-dectohex TmpHex = *($(MemoryMappedValueList),4)
  796.        Debug-Output "Current MemoryMappedBaseAddress = "$(TmpHex)
  797.        ForListDo $(MemoryRangeList)
  798.            Ifstr(i) $(TmpHex) == "0x"$($)
  799.                set-sub MemoryDefault = $(#),1
  800.            Endif
  801.        EndForListDo
  802.     else
  803.       GetRegValue $(ParametersKey) "SlotNumber" SlotNumber
  804.       Debug-Output "SlotNumber read from registry = "*($(SlotNumber),4)
  805.       set MemoryDefault = 0
  806.       set MemoryRangeList = {Slot*($(SlotNumber),4)}
  807.     endif
  808.        set-dectohex TmpHex = *($(IRQValueList),4)
  809.        Debug-Output "Current InterruptNumber = "$(TmpHex)
  810.        ForListDo $(IRQRangeList)
  811.            Ifstr(i) $(TmpHex) == "0x"$($)
  812.                set-sub IRQDefault = $(#),1
  813.            Endif
  814.        EndForListDo
  815.     ifstr(i) $(BusType) != "MCA"
  816.        set IOFound = $(FALSE)
  817.        set-dectohex TmpHex = *($(IOBaseValueList),4)
  818.        Debug-Output "Current IOBaseAddress = "$(TmpHex)
  819.        ForListDo $(IORangeList)
  820.            Ifstr(i) $(TmpHex) == "0x"$($)
  821.                set-sub IODefault = $(#),1
  822.                set IOFound = $(TRUE)
  823.            Endif
  824.        EndForListDo
  825.        ifint $(IOFound) == $(FALSE)
  826.          set IORangeList = {$(TmpHex)}
  827.          set IODefault = 0
  828.          set BusTypeNum = 2
  829.        endif
  830.     else
  831.        set IORangeList = {Slot*($(SlotNumber),4)}
  832.        set IODefault = 0
  833.     endif
  834.     set CtrlList = {}
  835.     set LineList = {}
  836.     ForListDo {"1","2"}
  837.       set CurrentLine = "Line"$($)
  838.       Debug-Output "CurrentLine = "$(CurrentLine)
  839.       OpenRegKey $(ParametersKey) "" $(CurrentLine) $(MAXIMUM_ALLOWED) LineKey
  840.             Ifstr $(LineKey) != $(KeyNull)
  841.                set ConcList = {}
  842.                ForListDo {"1","2","3","4","5","6","7","8","9","10","11","12","13","14","15","16"}
  843.                   set CurrentConc = "Concentrator"$($)
  844.                   OpenRegKey $(LineKey) "" $(CurrentConc) $(MAXIMUM_ALLOWED) ConcKey
  845.                   Ifstr $(ConcKey) != $(KeyNull)
  846.                      set PortNameList = {}
  847.                      set CurrentPort = ""
  848.                      set PortName = {}
  849.                      ForListDo {"1","2","3","4","5","6","7","8","9","10","11","12","13","14","15","16"}
  850.                         set CurrentPort = "Port"$($)
  851.                         OpenRegKey $(ConcKey) "" $(CurrentPort) $(MAXIMUM_ALLOWED) PortKey
  852.                         Ifstr $(PortKey) != $(KeyNull)
  853.                            GetRegValue $(PortKey) "DosDevices" PortName
  854.                            Ifstr $(PortNameList) == $(KeyNull)
  855.                               set PortNameList = *($(PortName),4)
  856.                            Else
  857.                               set PortNameList = >($(PortNameList), >($(CurrentPort),*($(PortName),4)))
  858.                            Endif
  859.                            CloseRegKey $(PortKey)
  860.                         EndIf
  861.                      EndForListDo
  862.                      CloseRegKey $(ConcKey)
  863.                      set ConcList = >($(ConcList),>($(CurrentConc),$(PortNameList)))
  864.                   EndIf
  865.                EndForListDo
  866.                CloseRegKey $(LineKey)
  867.                set TmpLine = >($(CurrentLine),$(ConcList))
  868.                set LineList = >($(LineList),$(TmpLine))
  869.             Endif
  870.             Debug-Output "LineList = "$(LineList)
  871.             set CtrlList = $(LineList)
  872.     EndForListDo
  873.     CloseRegKey $(ParametersKey)
  874.     CloseRegKey $(BaseKey)
  875. getAdapterSettingsExit = +
  876.     goto configureadapter
  877. writeparameters = +
  878.     Debug-Output "******************Entering writeparameters******************"
  879.     StartWait
  880.     Debug-Output "Trying to open: "$(!NTN_ServiceBase)"\"$(AdapterServiceName)
  881.     Debug-Output "AdapterParameters:"
  882.     Debug-Output $(AdapterParameters)
  883.     OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(AdapterServiceName) $(MAXIMUM_ALLOWED) BaseKey
  884.     Ifstr $(BaseKey) == $(KeyNull)
  885.         Debug-Output "Error opening BaseKey "$(!NTN_ServiceBase)"\"$(AdapterServiceName)
  886.         CloseRegKey $(BaseKey)
  887.         goto fatal
  888.     Endif
  889.     OpenRegKey $(BaseKey) "" "Parameters" $(MAXIMUM_ALLOWED) ParametersKey
  890.     Ifstr $(ParametersKey) == $(KeyNull)
  891.         Debug-Output "Assuming Parameters key does not exist!!!"
  892.         CloseRegKey $(BaseKey)
  893.         goto fatal
  894.     Endif
  895.     Debug-Output "AdapterParameters parsed: "
  896.     set MemoryAddress = *($(AdapterParameters),1)
  897.     set InterruptNumber = *($(AdapterParameters),2)
  898.     set IOBaseAddress = *($(AdapterParameters),3)
  899.     set HdwDeviceName = "\Device\"$(AdapterHardwareDriver)
  900.     Debug-Output "MemoryAddress = "$(MemoryAddress)
  901.     Debug-Output "InterruptNumber = "$(InterruptNumber)
  902.     Debug-Output "IOBaseAddress = "$(IOBaseAddress)
  903.     Debug-Output "HdwDeviceName = "$(HdwDeviceName)
  904.     SetRegValue $(ParametersKey) {MemoryMappedBaseAddress,$(NoTitle),$(!REG_VT_DWORD),$(MemoryAddress)}
  905.     SetRegValue $(ParametersKey) {IOBaseAddress,$(NoTitle),$(!REG_VT_DWORD),$(IOBaseAddress)}
  906.     SetRegValue $(ParametersKey) {InterruptNumber,$(NoTitle),$(!REG_VT_DWORD),$(InterruptNumber)}
  907.     SetRegValue $(ParametersKey) {HdwDeviceName,$(NoTitle),$(!REG_VT_SZ),$(HdwDeviceName)}
  908.     SetRegValue $(ParametersKey) {BusType,$(NoTitle),$(!REG_VT_DWORD),$(BusTypeNum)}
  909.     ifstr(i) $(BusType) == "MCA"
  910.       SetRegValue $(ParametersKey) {MCAPosId,$(NoTitle),$(!REG_VT_DWORD),$(MCAPosId)}
  911.       SetRegValue $(ParametersKey) {SlotNumber,$(NoTitle),$(!REG_VT_DWORD),$(SlotNumber)}
  912.     endif
  913.     set LineList = *($(AdapterParameters),4)
  914.     ForListDo $(LineList)
  915.       set LineObject = $($)
  916.       set LineName = *($(LineObject),1)
  917.       DeleteRegTree $(ParametersKey) $(LineName)
  918.       set ConcList = *($(LineObject),2)
  919.       Ifstr $(ConcList) != "{}"
  920.          shell "" ExCreateRegKey $(ParametersKey) $(LineName)
  921.          Ifstr(i) $($R0) != NO_ERROR
  922.              Debug-Output "Error creating registry key!"
  923.              set KeyHandle = $($R1)
  924.              CloseRegKey $(BaseKey)
  925.              goto fatal
  926.          Endif
  927.          set LineKey = $($R1)
  928.       Endif
  929.       ForListDo $(ConcList)
  930.          set ConcObject = $($)
  931.          set ConcName = *($(ConcObject),1)
  932.          set PortList = *($(ConcObject),2)
  933.          Debug-Output "   "$(ConcName)
  934.          Debug-Output "   "$(PortList)
  935.          shell "" ExCreateRegKey $(LineKey) $(ConcName)
  936.          Ifstr(i) $($R0) != NO_ERROR
  937.              Debug-Output "Error creating registry key!"
  938.              set KeyHandle = $($R1)
  939.              CloseRegKey $(LineKey)
  940.              goto fatal
  941.          Endif
  942.          set ConcKey = $($R1)
  943.          ForListDo $(PortList)
  944.             set PortObject = $($)
  945.             set PortName = *($(PortObject),1)
  946.             set PortDosDevices = *($(PortObject),2)
  947.             Debug-Output "      "$(PortName)"  -> "$(PortDosDevices)
  948.             shell "" ExCreateRegKey $(ConcKey) $(PortName)
  949.             Ifstr(i) $($R0) != NO_ERROR
  950.                 Debug-Output "Error creating registry key!"
  951.                 set KeyHandle = $($R1)
  952.                 CloseRegKey $(LineKey)
  953.                 goto fatal
  954.             Endif
  955.             set PortKey = $($R1)
  956.             SetRegValue $(PortKey) {DosDevices,$(NoTitle),$(!REG_VT_SZ),$(PortDosDevices)}
  957.          EndForListDo
  958.       EndForListDo
  959.     EndForListDo
  960.     EndWait
  961.     goto successful
  962. bindingadapter = +
  963.     Debug-Output "******************Entering bindingadapter******************"
  964.     LoadLibrary "x" dgconfig.dll DGCONFIG_HANDLE
  965.     set Error = "Binding: Sorry, not yet implemented."
  966.     goto fatal
  967. removeadapter = +
  968.     read-syms DebugOptions
  969.     Debug-Output "******************Entering removeadapter******************"
  970.     Debug-Output "OEMNADDS.INF: removeadapter"
  971.     Debug-Output "OEMNADDS.INF: Removing Hardware Components"
  972.     Debug-Output "OEMNADDS.INF: ProductKeyName = "$(ProductKeyName)
  973.     Debug-Output "OEMNADDS.INF: ProductSoftwareName = "$(ProductSoftwareName)
  974.     Debug-Output "OEMNADDS.INF: ProductSoftwareNameHdwDriver = "$(ProductSoftwareNameHdwDriver)
  975.     Debug-Output "OEMNADDS.INF: NTN_RegBase = "$(!NTN_RegBase)
  976.     ifstr(i) $(fRemoveDigi) == FALSE
  977.       install RemoveFiles
  978.       goto removeadapterExit
  979.     endif
  980.     LoadLibrary "x" dgconfig.dll DGCONFIG_HANDLE
  981.     Shell $(UtilityInf), RemoveHardwareComponent, $(Manufacturer), +
  982.         $(ProductSoftwareNameHdwDriver), $(!NTN_RegBase)
  983.     Debug-Output "OEMNADDS.INF: RemoveHardwareComponent return value = "$($R0)
  984.     Ifstr(i) $($R0) != NO_ERROR
  985.         Debug-Output "OEMNADDS.INF: RemoveHardwareComponent != NO_ERROR"
  986.     Endif
  987.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  988.         Debug-Output "ShellCode error"
  989.         goto ShellCodeError
  990.     endif
  991.     set RegistryErrorIndex = $($R0)
  992.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  993.         Debug-Output "fatal registry error"
  994.         goto fatalregistry
  995.     endif
  996.     shell $(UtilityInf), DecrementRefCount, $(ProductKeyName)
  997.     Debug-Output "OEMNADDS.INF: DecrementRefCount return value = "$($R0)
  998.     Ifstr(i) $($R0) != NO_ERROR
  999.         Debug-Output "OEMNADDS.INF: DecrementRefCount != NO_ERROR"
  1000.     Endif
  1001.     Shell $(UtilityInf), RemoveSoftwareComponent, $(Manufacturer), +
  1002.         $(ProductSoftwareName), TRUE
  1003.     Debug-Output "RemoveSoftwareComponent return value = "$($R0)
  1004.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  1005.         Debug-Output "ShellCode error"
  1006.         goto ShellCodeError
  1007.     endif
  1008.     set RegistryErrorIndex = $($R0)
  1009.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  1010.         Ifstr(i) $(RegistryErrorIndex) != REF_COUNT_NOT_ZERO
  1011.             goto fatalregistry
  1012.         endif
  1013.     endif
  1014.     install RemoveFiles
  1015. removeadapterExit = +
  1016.     Debug-Output "OEMNADDS.INF: Exiting removeadapter"
  1017.     goto end
  1018. UpgradeSoftware = +
  1019.     Debug-Output "******************Entering UpgradeSoftware******************"
  1020.     LoadLibrary "x" dgconfig.dll DGCONFIG_HANDLE
  1021.     ifstr(i) $(ProductKeyName) == $(!NTN_RegBase)
  1022.         OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct
  1023.         Ifstr $(KeyProduct) != $(KeyNull)
  1024.             GetRegValue $(KeyProduct),"MajorVersion", VersionInfo
  1025.             set Version = *($(VersionInfo), 4)
  1026.             Split-String $(!NTN_Infname), "\", FilenameList
  1027.             QueryListSize ListSize $(FilenameList)
  1028.             set !UG_Filename = *($(FilenameList), $(ListSize))
  1029.             install "Install-Update"
  1030.             ifstr(i) $(STF_INSTALL_OUTCOME) != STF_SUCCESS
  1031.                 goto fatal
  1032.             endif
  1033.             SetRegValue $(KeyProduct) {MajorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMajorVersion)}
  1034.             SetRegValue $(KeyProduct) {MinorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMinorVersion)}
  1035.             ifint $(Version) != $(ProductVersion)
  1036.             endif
  1037.             CloseRegKey $(KeyProduct)
  1038.         else
  1039.             goto fatalregistry
  1040.         endif
  1041.     else
  1042.         OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) +
  1043.               $(MAXIMUM_ALLOWED) NetworkCardKey
  1044.         Ifstr(i) $(NetworkCardKey) != $(KeyNull)
  1045.             GetRegValue $(NetworkCardKey),"ServiceName", ServiceNameInfo
  1046.             set ServiceName = *($(ServiceNameInfo), 4)
  1047.             OpenRegKey $(NetworkCardKey) "" "NetRules" +
  1048.                 $(MAXIMUM_ALLOWED) NetRuleKey
  1049.             Ifstr $(NetRuleKey) != $(KeyNull)
  1050.             else
  1051.                 goto fatalregistry
  1052.             endif
  1053.             CloseRegKey $(NetRules)
  1054.             CloseRegKey $(NetworkCardKey)
  1055.         else
  1056.             goto fatalregistry
  1057.         endif
  1058.         OpenRegKey $(!REG_H_LOCAL) "" +
  1059.               $(!NTN_ServiceBase)"\"$(ServiceName) +
  1060.               $(MAXIMUM_ALLOWED) ServiceKey
  1061.         Ifstr $(ServiceKey) != $(KeyNull)
  1062.             CloseRegKey $(ServiceKey)
  1063.         else
  1064.             goto fatalregistry
  1065.         endif
  1066.     endif
  1067.     goto end
  1068. successful = +
  1069.     Debug-Output "******************Entering successful******************"
  1070.     goto end
  1071. abandon = +
  1072.     Debug-Output "******************Entering abandon******************"
  1073.     ForListDo $(OEM_ABANDON_OPTIONS)
  1074.         Shell $(UtilityInf), RemoveHardwareComponent, $(Manufacturer), +
  1075.             $(ProductSoftwareName), $($)
  1076.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  1077.             Debug-Output "ShellCode error"
  1078.             goto ShellCodeError
  1079.         endif
  1080.         set RegistryErrorIndex = $($R0)
  1081.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  1082.             goto fatalregistry
  1083.         endif
  1084.     EndForListDo
  1085.     Ifstr(i) $(OEM_ABANDON_SOFTWARE) == TRUE
  1086.         Shell $(UtilityInf), RemoveSoftwareComponent, $(Manufacturer), +
  1087.             $(ProductSoftwareName), FALSE
  1088.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  1089.             Debug-Output "ShellCode error"
  1090.             goto ShellCodeError
  1091.         endif
  1092.         set RegistryErrorIndex = $($R0)
  1093.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  1094.             goto fatalregistry
  1095.         endif
  1096.     endif
  1097.     goto end
  1098. warning = +
  1099.     Debug-Output "******************Entering warning******************"
  1100.     Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), "WARNING", $(Error)
  1101.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  1102.         goto ShellCodeError
  1103.     endif
  1104.     ifstr(i) $($R1) == "OK"
  1105.         goto $(to)
  1106.     else-ifstr(i) $($R1) == "CANCEL"
  1107.         goto $(from)
  1108.     else
  1109.         goto "end"
  1110.     endif
  1111. nonfatalinfo = +
  1112.     Debug-Output "******************Entering nonfatalinfo******************"
  1113.     Set CommonStatus = STATUS_USERCANCEL
  1114.     Set Severity = STATUS
  1115.     goto nonfatalmsg
  1116. nonfatal = +
  1117.     Debug-Output "******************Entering nonfatal******************"
  1118.     Set Severity = NONFATAL
  1119.     goto nonfatalmsg
  1120. nonfatalmsg = +
  1121.     Debug-Output "******************Entering nonfatalmsg******************"
  1122.     ifstr(i) $(Error) == ""
  1123.         Set Severity = NONFATAL
  1124.         Shell $(UtilityInf) RegistryErrorString "SETUP_FAIL"
  1125.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  1126.             goto ShellCodeError
  1127.         endif
  1128.         set Error = $($R0)
  1129.     endif
  1130.     Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), $(Severity), $(Error)
  1131.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  1132.         goto ShellCodeError
  1133.     endif
  1134.     ifstr(i) $($R1) == "OK"
  1135.         goto $(from)
  1136.     else
  1137.         goto "end"
  1138.     endif
  1139. fatalregistry = +
  1140.     Debug-Output "******************Entering fatalregistry******************"
  1141.     Shell $(UtilityInf) RegistryErrorString $(RegistryErrorIndex)
  1142.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  1143.        Debug-Output "fatalregistry: shell to find RegistryErrorString failed."
  1144.        goto ShellCodeError
  1145.     endif
  1146.     set Error = $($R0)" - service "$(DigiSpecificString)"."
  1147.     ifstr(i) $(fRemoveDigi) == TRUE
  1148.         read-syms AbortMessage$(!STF_LANGUAGE)
  1149.         set Error = $(Error)$(!LF)$(!LF)$(AbortText)
  1150.     endif
  1151.     goto fatal
  1152. fataldetect = +
  1153.     Debug-Output "******************Entering fataldetect******************"
  1154.     Shell $(UtilityInf),RegistryErrorString,CANNOT_DETECT
  1155.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  1156.         Debug-Output "ShellCode error: cannot get an error string."
  1157.         goto ShellCodeError
  1158.     endif
  1159.     set Error = $($R0)
  1160.     Goto fatal
  1161. fatal = +
  1162.     Debug-Output "******************Entering fatal******************"
  1163.     Debug-Output "OEMNADDS.INF: ---- fatal called"
  1164.     Shell $(subroutninf) SetupMessage, $(!STF_LANGUAGE), "FATAL", $(Error)
  1165.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  1166.         Debug-Output "fatal: shell to SetupMessage failed."
  1167.         goto ShellCodeError
  1168.     endif
  1169.     goto setfailed
  1170. ShellCodeError = +
  1171.     Debug-Output "******************Entering ShellCodeError******************"
  1172.     set DlgType      = "MessageBox"
  1173.     set STF_MB_TITLE = "Error: "$(FunctionTitle)
  1174.     set STF_MB_TEXT  = "Shell Code Error"
  1175.     set STF_MB_TYPE  = 1
  1176.     set STF_MB_ICON  = 3
  1177.     set STF_MB_DEF   = 1
  1178.     ui start "Error Message"
  1179.     goto setfailed
  1180. setfailed = +
  1181.     Debug-Output "******************Entering setfailed******************"
  1182.     set CommonStatus = STATUS_FAILED
  1183.     ifstr(i) $(fRemoveDigi) == TRUE
  1184.         set fRemoveDigi = FALSE
  1185.         goto removeadapter
  1186.     endif
  1187.     goto end
  1188. end = +
  1189.     Debug-Output "******************Entering end******************"
  1190.     goto term
  1191. term = +
  1192.     ifstr(i) $(DGCONFIG_HANDLE) != $(HandleNull)
  1193.       FreeLibrary $(DGCONFIG_HANDLE)
  1194.     endif
  1195.     Debug-Output "******************Entering term -- GoodBye!!!******************"
  1196.     Return $(CommonStatus)
  1197. [RemoveFiles]
  1198.    Debug-Output "******************Entering [RemoveFiles]******************"
  1199.    set RemoveList = {}
  1200.    set RenameList = {}
  1201.    OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyNameHdwDriver) +
  1202.               $(MAXIMUM_ALLOWED) KeyProductHdwDriver
  1203.    ifstr $(KeyProductHdwDriver) == $(KeyNull)
  1204.       CloseRegKey $(KeyProductHdwDriver)
  1205.       set RenameList = >($(RenameList), $(!STF_WINDOWSSYSPATH)"\drivers\"$(AdapterHardwareDriver)".sys")
  1206.    endif
  1207.    OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) +
  1208.               $(MAXIMUM_ALLOWED) KeyProduct
  1209.    ifstr $(KeyProduct) == $(KeyNull)
  1210.       CloseRegKey $(KeyProduct)
  1211.       set RenameList = >($(RenameList), $(!STF_WINDOWSSYSPATH)"\drivers\"$(ProductSoftwareName)".sys")
  1212.       set RenameList = >($(RenameList), $(!STF_WINDOWSSYSPATH)"\dgconfig.dll")
  1213.       set RemoveList = >($(RemoveList), $(!STF_WINDOWSSYSPATH)"\dgconfig.hlp")
  1214.    endif
  1215.    Debug-Output "RemoveList = "$(RemoveList)
  1216.    Debug-Output "RenameList = "$(RenameList)
  1217.    ForListDo $(RemoveList)
  1218.        Debug-Output "Removing "$($)
  1219.        LibraryProcedure Status , $(!LIBHANDLE), DelFile $($)
  1220.        Debug-Output "Status is "$(Status)
  1221.    EndForListDo
  1222.    ForListDo $(RenameList)
  1223.        Debug-Output "RenameList entry = "$($)
  1224.        Split-String $($) "\" FilePath
  1225.        QueryListSize PathLen $(FilePath)
  1226.        Split-String *($(FilePath),$(PathLen)) "." FullFileName
  1227.        Set FileName = *($(FullFileName),1)
  1228.        Debug-Output "FileName is "$(FileName)
  1229.        LibraryProcedure STATUS, $(!LIBHANDLE),CheckFileExistance $(!STF_WINDOWSSYSPATH)"\DRIVERS\"$(FileName)".old"
  1230.        Debug-Output "CheckFile Status = "$(STATUS)
  1231.        ifstr(i) $(STATUS) == YES
  1232.            LibraryProcedure STATUS, $(!LIBHANDLE), DelFile $(!STF_WINDOWSSYSPATH)"\DRIVERS\"$(FileName)".old"
  1233.            Debug-Output "Delfile Status = "$(STATUS)
  1234.            LibraryProcedure STATUS, $(!LIBHANDLE), DelFile $($)
  1235.            Debug-Output "Delfile Status = "$(STATUS)
  1236.        endif
  1237.        ifstr(i) $(fRemoveDigi) == TRUE
  1238.          Debug-Output "Renaming from "$($)
  1239.          Debug-Output "Renaming to "$(!STF_WINDOWSSYSPATH)"\DRIVERS\"$(FileName)".old"
  1240.          LibraryProcedure Status1 , $(!LIBHANDLE), RenFile $($), $(!STF_WINDOWSSYSPATH)"\DRIVERS\"$(FileName)".old"
  1241.          Debug-Output "Status is "$(Status1)
  1242.          AddFileToDeleteList $(!STF_WINDOWSSYSPATH)"\DRIVERS\"$(FileName)".old"
  1243.        endif
  1244.    EndForListDo
  1245.    exit
  1246. [ExCreateRegKey]
  1247.     Debug-Output "******************Entering [ExCreateRegKey]******************"
  1248.     set ECR_Result          = NO_ERROR
  1249.     set ECR_BaseKeyHandle   = $($0)
  1250.     set ECR_NewPath         = $($1)
  1251.     set KeyNull         = ""
  1252.     set MAXIMUM_ALLOWED   = 33554432
  1253.     Debug-Output "ExCreateRegKey - ECR_BaseKeyHandle = "$(ECR_BaseKeyHandle)
  1254.     Debug-Output "                 ECR_NewPath = "$(ECR_NewPath)
  1255.     Debug-Output "                 MAXIMUM_ALLOWED = "$(MAXIMUM_ALLOWED)
  1256.     Debug-Output "                 KeyNull = "$(KeyNull)
  1257.     OpenRegKey $(ECR_BaseKeyHandle) "" $(ECR_NewPath) $(MAXIMUM_ALLOWED) +
  1258.                ECR_BaseKey
  1259.     Debug-Output "ECR_BaseKey = "$(ECR_BaseKey)
  1260.     Debug-Output "    OpenRegKey returned "$($R0)
  1261.     Ifstr $(ECR_BaseKey) == $(KeyNull)
  1262.         Debug-Output "ECR_BaseKey == KeyNull"
  1263.     Else
  1264.         Debug-Output "ECR_BaseKey != KeyNull"
  1265.         set ECR_KeyHandle = $(ECR_BaseKey)
  1266.         goto  ECR_Return
  1267.     Endif
  1268.     set ECR_TmpPath = ""
  1269.     Split-String $(ECR_NewPath) "\" ECR_PList
  1270.     Debug-Output "ECR_PList = "$(ECR_PList)
  1271.     ForListDo $(ECR_PList)
  1272.         Ifstr(i) $($) != "\"
  1273.             Ifint $(#) == 1
  1274.                 set ECR_TmpPath = $($)
  1275.             Else
  1276.                 set ECR_TmpPath = $(ECR_TmpPath)"\"$($)
  1277.             Endif
  1278.             Debug-Output "Determining if "$(ECR_TmpPath)" exists"
  1279.             OpenRegKey $(ECR_BaseKeyHandle) "" $(ECR_TmpPath) $(MAXIMUM_ALLOWED) ECR_BaseKey
  1280.             Ifstr $(ECR_BaseKey) == $(KeyNull)
  1281.                 Debug-Output "Creating "$(ECR_TmpPath)
  1282.                 CreateRegKey $(ECR_BaseKeyHandle)  {$(ECR_TmpPath),0,GenericClass} "" $(MAXIMUM_ALLOWED) "" ECR_KeyHandle
  1283.                 Ifstr(i) $(ECR_KeyHandle) == $(KeyNull)
  1284.                     set ECR_Result = $($R0)
  1285.                     goto ECR_Return
  1286.                 Endif
  1287.             Endif
  1288.         Endif
  1289.     EndForListDo
  1290. ECR_Return = +
  1291.     return $(ECR_Result) $(ECR_KeyHandle)
  1292. [DebugExternalGlobals]
  1293.     Set InfName = "OEMNADDS.INF"
  1294.     Debug-Output $(InfName)" NTN_Origination = "$(!NTN_Origination)
  1295.     Debug-Output $(InfName)" NTN_InstallMode = "$(!NTN_InstallMode)
  1296.     Debug-Output $(InfName)" NTN_RegBase = "$(!NTN_RegBase)
  1297.     Debug-Output $(InfName)" NTN_SoftwareBase = "$(!NTN_SoftwareBase)
  1298.     Debug-Output $(InfName)" NTN_ServiceBase = "$(!NTN_ServiceBase)
  1299.     Debug-Output $(InfName)" STF_NTPATH = "$(!STF_NTPATH)
  1300.     Debug-Output $(InfName)" STF_NTWINDOWSSYSPATH = "$(!STF_WINDOWSSYSPATH)
  1301.     Debug-Output $(InfName)" STF_CWDIR = "$(!STF_CWDIR)
  1302.     Debug-Output $(InfName)" STF_LANGUAGE = "$(!STF_LANGUAGE)
  1303.     Debug-Output $(InfName)" STF_NCDETECT  = "$(!STF_NCDETECT)
  1304.     Debug-Output $(InfName)" STF_NCOPTION  = "$(!STF_NCOPTION)
  1305.     Debug-Output $(InfName)" STF_NCDETCARD = "$(!STF_NCDETCARD)
  1306.     Debug-Output $(InfName)" STF_NCDETINFO = "$(!STF_NCDETINFO)
  1307.     Debug-Output $(InfName)" STF_INSTALL_MODE = "$(!STF_INSTALL_MODE)
  1308.     Debug-Output $(InfName)" STF_CONTEXTINFNAME = "$(!STF_CONTEXTINFNAME)
  1309.     return
  1310. [DebugConfiguration]
  1311.     Set InfName = "OEMNADDS.INF"
  1312.     Debug-Output $(InfName)" **CONFIGURATION STATE: "$($0)
  1313.     Debug-Output $(InfName)" IRQ_Level is "$(!p:IRQ_Level)
  1314.     Debug-Output $(InfName)" IOBaseAddrValue is "$(!p:IOBaseAddrValue)
  1315.     Debug-Output $(InfName)" TransceiverValue is "$(!p:TransceiverValue)
  1316.     Debug-Output $(InfName)" MemBaseAddrDec is "$(!p:MemBaseAddrDec)
  1317.     Debug-Output $(InfName)" MappedValue is "$(!p:MappedValue)
  1318.     return
  1319. [AdapterSettings-ntcx]
  1320. IRQRangeList = {"Disabled"}
  1321. MemoryRangeList = {"C0000","C8000","D0000","D8000","E0000","E8000"}
  1322. IORangeList = {"108","118","128","208","228","308","328"}
  1323. IRQDefault = 0
  1324. MemoryDefault = 2
  1325. IODefault = 4
  1326. [AdapterSettings-ntxem]
  1327. IRQRangeList = {"Disabled"}
  1328. MemoryRangeList = {"C0000","C8000","D0000","D8000","E0000","E8000"}
  1329. IORangeList = {"104","114","124","204","224","304","324"}
  1330. IRQDefault = 0
  1331. MemoryDefault = 2
  1332. IODefault = 4
  1333. [AdapterSettings-nt4i]
  1334. IRQRangeList = {"Disabled"}
  1335. MemoryRangeList = {"C0000","D0000","E0000"}
  1336. IORangeList = {"100","110","120","200","220","300","320"}
  1337. IRQDefault = 0
  1338. MemoryDefault = 1
  1339. IODefault = 4
  1340. [AdapterSettings-nt8i]
  1341. IRQRangeList = {"Disabled"}
  1342. MemoryRangeList = {"C0000","D0000","E0000"}
  1343. IORangeList = {"100","110","120","200","220","300","320"}
  1344. IRQDefault = 0
  1345. MemoryDefault = 1
  1346. IODefault = 4
  1347. [AdapterSettings-nt16i]
  1348. IRQRangeList = {"Disabled"}
  1349. MemoryRangeList = {"C0000","D0000","E0000"}
  1350. IORangeList = {"100","110","120","200","220","300","320"}
  1351. IRQDefault = 0
  1352. MemoryDefault = 1
  1353. IODefault = 4
  1354. [AdapterSettings-nt16e]
  1355. IRQRangeList = {"Disabled"}
  1356. MemoryRangeList = {"C0000","D0000","E0000", }
  1357. IORangeList = {"100","110","120","200","220","300","320"}
  1358. IRQDefault = 0
  1359. MemoryDefault = 1
  1360. IODefault = 4
  1361. [AdapterSettings-nt8e]
  1362. IRQRangeList = {"Disabled"}
  1363. MemoryRangeList = {"C0000","D0000","E0000", }
  1364. IORangeList = {"100","110","120","200","220","300","320"}
  1365. IRQDefault = 0
  1366. MemoryDefault = 1
  1367. IODefault = 4
  1368. [AdapterSettings-nt4e]
  1369. IRQRangeList = {"Disabled"}
  1370. MemoryRangeList = {"C0000","D0000","E0000", }
  1371. IORangeList = {"100","110","120","200","220","300","320"}
  1372. IRQDefault = 0
  1373. MemoryDefault = 1
  1374. IODefault = 4
  1375. [AdapterSettings-2Port]
  1376. IRQRangeList = {"Disabled"}
  1377. MemoryRangeList = {"C0000","C2000","C4000","C6000","C8000", "CA000", "CC000", "CE000", +
  1378.                "D0000","D2000","D4000","D6000","D8000", "DA000", "DC000", "DE000", +
  1379.                "E0000","E2000","E4000","E6000","E8000", "EA000", "EC000", "EE000" }
  1380. IORangeList = {"100","110","120","200","220","300","320"}
  1381. IRQDefault = 0
  1382. MemoryDefault = 8
  1383. IODefault = 4
  1384. [AdapterSettings-4Port]
  1385. IRQRangeList = {"Disabled"}
  1386. MemoryRangeList = {"C0000","C2000","C4000","C6000","C8000", "CA000", "CC000", "CE000", +
  1387.                "D0000","D2000","D4000","D6000","D8000", "DA000", "DC000", "DE000", +
  1388.                "E0000","E2000","E4000","E6000","E8000", "EA000", "EC000", "EE000" }
  1389. IORangeList = {"100","110","120","200","220","300","320"}
  1390. IRQDefault = 0
  1391. MemoryDefault = 8
  1392. IODefault = 4
  1393. [AdapterSettings-8Port]
  1394. IRQRangeList = {"Disabled"}
  1395. MemoryRangeList = {"C0000","C2000","C4000","C6000","C8000", "CA000", "CC000", "CE000", +
  1396.                "D0000","D2000","D4000","D6000","D8000", "DA000", "DC000", "DE000", +
  1397.                "E0000","E2000","E4000","E6000","E8000", "EA000", "EC000", "EE000" }
  1398. IORangeList = {"100","110","120","200","220","300","320"}
  1399. IRQDefault = 0
  1400. MemoryDefault = 8
  1401. IODefault = 4
  1402. [BindingInfo-DigiFEP5]
  1403. BindingInfo =   {+
  1404.                 "digiFEP5Driver ntcxDriver non exclusive 100", +
  1405.                 "digiFEP5Driver ntxemDriver non exclusive 100", +
  1406.                 "digiFEP5Driver ntxallDriver non exclusive 100" +
  1407.                 }
  1408. [BindingInfo-ntxem]
  1409. BindingInfo     = {+
  1410.                   $(AdapterHardwareDriver)"Driver "$(AdapterHardwareDriver)"Adapter non exclusive 100", +
  1411.                   }
  1412. [BindingInfo-ntcx]
  1413. BindingInfo     = {+
  1414.                   $(AdapterHardwareDriver)"Driver "$(AdapterHardwareDriver)"Adapter non exclusive 100", +
  1415.                   }
  1416. [BindingInfo-ntxall]
  1417. BindingInfo     = {+
  1418.                   $(AdapterHardwareDriver)"Driver "$(AdapterHardwareDriver)"Adapter non exclusive 100" +
  1419.                   }
  1420. [InstallResources]
  1421.     set STF_VITAL = ""
  1422.     Debug-Output "OEMNADDS.INF: [InstallResources]"
  1423.     AddSectionFilesToCopyList Files-Resource $(!SourceDir) $(!STF_WINDOWSSYSPATH)
  1424.     CopyFilesInCopyList
  1425.     Debug-Output "OEMNADDS.INF: [InstallResources] - Exiting"
  1426.     exit
  1427. [Install-Option]
  1428.     set STF_VITAL = ""
  1429.     ifstr(i) $(AddCopy) == "YES"
  1430.         AddSectionFilesToCopyList Files-Resource $(SrcDir) $(!STF_WINDOWSSYSPATH)
  1431.         AddSectionFilesToCopyList Files-DigiFEP5 $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
  1432.         AddSectionFilesToCopyList Files-$(Option) $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
  1433.     endif
  1434.     ifstr(i) $(DoCopy) == "YES"
  1435.        set !STF_NCPA_FLUSH_COPYLIST = TRUE
  1436.        CopyFilesInCopyList
  1437.     endif
  1438.     ifstr(i) $(DoConfig) == "YES"
  1439.     endif
  1440.     Exit
  1441. [Source Media Descriptions]
  1442.     1  = "Windows NT Setup Disk #1"  , TAGFILE = disk1
  1443.     2  = "Windows NT Setup CD-ROM Disk"  , TAGFILE = disk2
  1444. [ProductType]
  1445. STF_PRODUCT  = Winnt
  1446. STF_PLATFORM = I386
  1447. [Files-Inf]
  1448. 2,    oemsetup.inf,     SIZE=1000,    RENAME=$(!UG_Filename)
  1449. [Files-DigiBoard2Port]
  1450. 2,NTXALL.SYS , SIZE=999
  1451. [Files-DigiBoard4e]
  1452. 2,NTXALL.SYS , SIZE=999
  1453. [Files-DigiBoard4Port]
  1454. 2,NTXALL.SYS , SIZE=999
  1455. [Files-DigiBoard8e]
  1456. 2,NTXALL.SYS , SIZE=999
  1457. [Files-DigiBoard8i]
  1458. 2,NTXALL.SYS , SIZE=999
  1459. [Files-DigiBoard8Port]
  1460. 2,NTXALL.SYS , SIZE=999
  1461. [Files-DigiBoardCX]
  1462. 2,NTCX.SYS , SIZE=999
  1463. [Files-DigiBoardXem]
  1464. 2,NTXEM.SYS , SIZE=999
  1465. [Files-DigiFEP5]
  1466. 2,DIGIFEP5.SYS , SIZE=999
  1467. [Files-Resource]
  1468. 2,DGCONFIG.HLP , SIZE=999
  1469. 2,DGCONFIG.DLL , SIZE=999
  1470. [OptionsTextENG]
  1471.     DigiBoardCX     = "DigiBoard C/X Adapter" 
  1472.     DigiBoardXem    = "DigiBoard PC/Xem Adapter"
  1473.     DigiBoard8i     = "DigiBoard PC/8i Adapter"
  1474.     DigiBoard16i    = "DigiBoard PC/16i Adapter"
  1475.     DigiBoard2Port  = "DigiBoard 2Port Adapter"
  1476.     DigiBoard4Port  = "DigiBoard 4Port Adapter"
  1477.     DigiBoard8Port  = "DigiBoard 8Port Adapter"
  1478.     DigiBoard4e     = "DigiBoard PC/4e Adapter"
  1479.     DigiBoard8e     = "DigiBoard PC/8e Adapter"
  1480.     DigiBoard16e    = "DigiBoard PC/16e Adapter"
  1481. [OptionsTextMCAENG]
  1482.     DigiBoardCX     = "DigiBoard MC C/X Adapter" 
  1483.     DigiBoardXem    = "DigiBoard MC/Xem Adapter"
  1484.     DigiBoard4i     = "DigiBoard MC/4i Adapter"
  1485.     DigiBoard8i     = "DigiBoard MC/8i Adapter"
  1486.     DigiBoard16i    = "DigiBoard MC/16i Adapter"
  1487.     DigiBoard2Port  = "DigiBoard 2Port Adapter"
  1488.     DigiBoard4Port  = "DigiBoard 4Port Adapter"
  1489.     DigiBoard8Port  = "DigiBoard 8Port Adapter"
  1490. [FileConstantsENG]
  1491.     ProCaption   = "DigiBoard Setup" 
  1492.     ProCancel    = "Cance&l"
  1493.     ProCancelMsg = "DigiBoard Adapters and/or Drivers are not correctly installed. "+
  1494.                    "Are you sure you want to cancel copying files?"
  1495.     ProCancelCap = "DigiBoard Setup Message"
  1496.     ProText1     = "Copying:"
  1497.     ProText2     = "To:"
  1498.     Error         = "Unable to determine proper source disk location; copy cannot be performed."
  1499.     FunctionTitle   ="DigiBoard Setup"
  1500.     ProductSoftwareDescription          = "DigiBoard FEP 5 Adapter Driver"
  1501.     ProductSoftwareDescriptionHdwDriver = "DigiBoard "$(AdapterTitle)" Miniport Driver"
  1502.     ProductSoftwareTitle    = "DigiBoard FEP 5 Driver"
  1503.     ProductSoftwareTitleHdwDriver = "DigiBoard "$(AdapterTitle)" Miniport Driver"
  1504.    ConfigurationTitle = "DigiBoard "$(AdapterTitle)" Adapter Setup"
  1505.     ProductHardwareDescription      = "DigiBoard "$(AdapterTitle)" Adapter"
  1506.     ProductHardwareTitle        = "DigiBoard "$(AdapterTitle)" Adapter"
  1507. [DialogConstantsENG]
  1508.     Help        = "&Help"
  1509.     Exit        = "E&xit"
  1510.     OK          = "OK"
  1511.     HelpContext = ""
  1512.     Continue    = "C&ontinue"
  1513.     Cancel      = "C&ancel"
  1514. [UpdatingConfigurationENG]
  1515.     UpdatingConfiguration      = "Updating new configuration..."
  1516. [AbortMessageENG]
  1517.   AbortText  =  "Aborting DigiBoard Setup. Please reboot the system "+
  1518.                 "to fix the problem."
  1519.  
  1520.  
  1521.  
  1522.